{% extends "base.html" %}


{% block title %}Preview your remark{% endblock %}


{% block content %}
  {% load markup i18n %}
  {{ remark_form.errors }}
  
  <div class="remark_list">
    <h2>Your remark <em>Click 'Post' below to make live</em></h2>
    <div>
      <h5 class="name">
        <a href="#" title="Permalink to {{ remark.person_name }}'s comment" class="count">1</a> 
        {% if remark.person_url %}<a href="{{ remark.person_url }}">{{ remark.person_name }}</a> says...{% else %}{{ remark.person_name }} says...{% endif %}
      </h5>
      {{ remark.remark|urlizetrunc:"60"|markdown }}
      <p class="date">Posted at {% now "P" %} on {% now "F j, Y" %}</p>
    </div>
  </div>
  
  <div class="remark_form">
    <h2>Edit remark</h2>
    <form action="/remarks/post/" method="post">
      <fieldset>
        <p><label for="id_person_name">{% trans "Your name:" %}</label> 
          {{ remark_form.person_name }} <small>*required</small></p>
        <p><label for="id_person_email">{% trans "Your email:" %}</label> 
          {{ remark_form.person_email }}</p>
        <p><label for="id_person_url">{% trans "Your URL:" %}</label> 
          {{ remark_form.person_url }}</p>
        <p><label for="id_remark">{% trans "Remark:" %}</label><br>
          {{ remark_form.remark }}</p>
        
        <p>
          <input type="hidden" name="target" value="{{ target }}">
          <input type="hidden" name="gonzo" value="{{ hash }}">
          <input type="submit" name="preview" value="{% trans "Preview" %}" class="button"> or <input type="submit" name="post" value="{% trans "Post" %}" class="button">
        </p>
    </form>
  </div>
{% endblock %}